<?xml version="1.0" encoding="UTF-8" ?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
    "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" 
		xmlns:og="http://opengraphprotocol.org/schema/"
		xmlns:fb="http://www.facebook.com/2008/fbml" xml:lang="de">
<head>

{assign var="languageTextFile" value='themes/desktop/lang/'|cat:$languageCode}
{assign var="languageTextFile" value=$languageTextFile|cat:'/text.tpl'}
{include file=$languageTextFile}

{assign var="canonical" value=""}
{assign var="robots" value="index,follow"}

{if $is_404==true}
	<title>{$TEXT_PAGE_NOT_FOUND} - {$TEXT_SITE_NAME}</title>
	{assign var="robots" value="noindex,nofollow"}
	{assign var="canonical" value=0}
{else}
	{if $pageType == "index"}
		<title>{$TEXT_SITE_NAME}</title>
	{/if}
	{if $pageType == "category"}
		{foreach from=$categoryList item=categoryItem}
			{if $categoryItem.url==$pageItem}
				{assign var="canonical" value="k/"|cat:$categoryItem.url}
				<title>{$categoryItem.name} - {$TEXT_SITE_NAME}</title>
			{/if}
		{/foreach}
	{/if}
	{if $pageType == "article"}
		{assign var="canonical" value=$article.url|cat:".html"}
		<title>{$article.title} - {$TEXT_SITE_NAME}</title>
		
		<meta property="og:title" content="{$article.title}"/>
		<meta property="og:type" content="article"/>
		<meta property="og:url" content="http://{$primary_domain}/{$article.url|cat:".html"}"/>
		{if $article.image|strlen > 0}
			<meta property="og:image" content="http://{$primary_domain}/img/{$article.image}"/>
		{/if}
		<meta property="og:site_name" content="Kammerath Network"/>
		<meta property="og:locale" content="de_DE" />
	{/if}
	{if $pageType == "search"}
		{assign var="robots" value="noindex,follow"}
		<title>{$pageItem} - {$TEXT_SITE_NAME}</title>
	{/if}
{/if}

<meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />
<meta name="robots" content="{$robots}" />

{if $languageCode == "de-DE"}
<meta name="google-site-verification" content="BPUF-GY02lLIK2jX7Bv7eHPAjVjd7dxWoAJD2rPCdw8" />
{/if}

{if $languageCode == "en-GB"}
<meta name="google-site-verification" content="58Pf3rK_KjlKtt2rrgDBaY2SkIKG13dfEs8DuBpQ-04" />
{/if}
<meta property="fb:admins" content="1664544556" />
<meta property="fb:app_id" content="138524109534751" />

{if $canonical !== 0}
	<link rel="canonical" href="http://{$primary_domain}/{$canonical}" />
{/if}

<link rel="stylesheet" type="text/css" media="all" href="http://{$cdn_host_css}/minpack{$minpack_css_tag}.css" />
<link rel="shortcut icon" href="/favicon.ico" />
<meta name="verification" content="a70dedf2998e5205930658a63d49e33e" />
</head>
<body>
	<table id="knMaster" cellpadding="0" cellspacing="0">
		<tr>
			<td id="knMasterLeft" valign="top">
				<div id="knMasterLeftTop"></div>
				<div id="knMasterLeftBreaker"></div>
				<div id="knMasterLeftSpace">
					<!-- 160x600-Links -->
				</div>
			</td>
			<td id="knMasterCenter" valign="top">
				<div id="knMasterCenterTop">
					<div id="knMasterCenterTopBorderLeft"
						class="knMasterCenterTopBorder"></div>
					<div id="knMasterCenterTopContent" onclick="location.href='/';"></div>
					<div id="knMasterCenterTopBorderRight"
						class="knMasterCenterTopBorder"></div>

					<!-- Google Translator -->
					<div id="knMasterTranslator">
						{include file="themes/desktop/translate.tpl"}
					</div>
				</div>

				<div id="knMasterCenterBreaker">
					<div id="knMasterCenterBreakerContent"></div>

				</div>


				<div id="knMasterCenterContent">
					<div id="knMasterFacebook">
						{if $loggedIn == true}
							<div id="knMasterFacebookPicture">
								<img src="https://graph.facebook.com/{$user->id}/picture?type=square" />
							</div>
							<div id="knMasterFacebookButton">
								<img id="knFacebookLogoutButton" class="knFacebookButton" src="/themes/desktop/lang/{$languageCode}/facebook-logout.jpg" />
							</div>
							<div id="knMasterFacebookText">
								<strong>{$TEXT_GREETING}, {$user->first_name}!</strong> 
								{$TEXT_LOGGEDIN_TEXT}
							</div>
						{else}
							<div id="knMasterFacebookPicture">
								<img src="/themes/desktop/img/facebook-user.jpg" width="50" height="50" alt="Du bist nicht angemeldet" />
							</div>
							<div id="knMasterFacebookButton">
								<img id="knFacebookLoginButton" class="knFacebookButton" src="/themes/desktop/lang/{$languageCode}/facebook-login.jpg" alt="Anmelden mit deinem Facebook-Konto" />
							</div>
							<div id="knMasterFacebookText">
								<strong>{$TEXT_GREETING_ANONYMOUS}</strong> 
								{$TEXT_NOT_LOGGEDIN_TEXT}
							</div>						
						{/if}
						<div style="clear:both;"></div>
					</div>
					
					
					<!-- menu for the categories -->
					<div id="knMasterCenterMenu">
								{assign var="menuItemId" value=0}
								{foreach from=$categoryList item=category}
									<div id="knMasterCenterMenuItem{$menuItemId}" class="knMasterCenterMenuItem">
										<a href="/k/{$category.url}">
											{$category.name}</a> ({$category.article_count})
									</div>
									{assign var="menuItemId" value=$menuItemId+1}
								{/foreach}
						<div style="clear: both;"></div>
					</div>
						{if $is_404==true}
							{assign var="errorTextFile" value='themes/desktop/lang/'|cat:$languageCode}
							{assign var="errorTextFile" value=$errorTextFile|cat:'/404.tpl'}
							{include file=$errorTextFile}
						{else}
							<!--
							Page Type: {$pageType}
							Page Item: {$pageItem}
							-->
							{if $pageType == "search"}
								{include file='themes/desktop/search.tpl'}
							{/if}
							{if $pageType == "index"}
								{include file='themes/desktop/index.tpl'}
							{/if}
							{if $pageType == "article"}
								{include file='themes/desktop/article.tpl'}
							{/if}
							{if $pageType == "category"}
								{include file='themes/desktop/category.tpl'}
							{/if}
 						{/if}
 					<center>
					<div id="knMasterShare">
						<div id='knShareTwitter' class="knShareButton" onclick="javascript:share('twitter');"></div>
						<div id='knShareFacebook' class="knShareButton" onclick="javascript:share('facebook');"></div>
						<div id='knShareGoogle' class="knShareButton" onclick="javascript:share('google');"></div>
						<div id='knShareYahoo' class="knShareButton" onclick="javascript:share('yahoo');"></div>
						<div id='knShareLinkedIn' class="knShareButton" onclick="javascript:share('linkedin');"></div>
						<div id='knShareBebo' class="knShareButton" onclick="javascript:share('bebo');"></div>
						<div id='knShareBlogger' class="knShareButton" onclick="javascript:share('blogger');"></div>
						<div id='knShareDelicious' class="knShareButton" onclick="javascript:share('delicious');"></div>
						<div id='knShareDigg' class="knShareButton" onclick="javascript:share('digg');"></div>
						<div id='knShareStumbleUpon' class="knShareButton" onclick="javascript:share('stumbleupon');"></div>
						<div id='knShareXing' class="knShareButton" onclick="javascript:share('xing');"></div>
						<div style="clear:both;"></div>
					</div>
					</center>
					<div id="knMasterLegal">
						<center>
							<!-- 468x60-Unten -->
							<div id="knMasterSpaceBottom"></div>
						</center>
						{assign var="legalFooterFile" value='themes/desktop/lang/'|cat:$languageCode}
						{assign var="legalFooterFile" value=$legalFooterFile|cat:'/legalfooter.tpl'}
						{include file=$legalFooterFile}					
					</div>
				</div>
			</td>
			<td id="knMasterRight" valign="top">
				<!-- SEARCHBOX -->
				<div class="knSidebarBox">
					<div class="knSidebarBoxTitle">{$TEXT_SEARCH_SITE}</div>
					<div class="knSidebarBoxBody">
							<input id="knSiteSearchText" name="s" type="text"
								value="{$TEXT_SEARCH_TERM}"
								onclick="{literal}javascript:if(this.value=='{/literal}{$TEXT_SEARCH_TERM}{literal}'){this.value='';}{/literal}"
								onblur="{literal}javascript:if(this.value==''){this.value='{/literal}{$TEXT_SEARCH_TERM}{literal}';}{/literal}"
								onkeyup="{literal}javascript:if(event.keyCode==13){search(this.value);}{/literal}" />
					</div>
				</div> 
				
				<!-- CATEGORY BOX -->
				<div id="knSidebarCategoriesBox" class="knSidebarBox">
					<div class="knSidebarBoxTitle">{$TEXT_CATEGORIES}</div>
					<div class="knSidebarBoxBody">
						<ul>
							{foreach from=$categoryList item=category}
								<li class="cat-item cat-item-6"><a
									href="/k/{$category.url}"
									title="Alle Beiträge in der Kategorie {$category.name} anzeigen">{$category.name}</a> ({$category.article_count})</li>
							{/foreach}
						</ul>
					</div>
				</div> 

				{if $is_admin == true}
					<!-- ADMINBOX -->
					<div id="knSidebarAdminBox" class="knSidebarBox">
						<div class="knSidebarBoxTitle">Administration</div>
						<div class="knSidebarBoxBody">
							<ul>
								<li style="list-style-type:square;font-weight:bold;">
									<a href="#" onclick="javascript:openAdminWindow();">Administration</a>
								</li>
								<li style="list-style-type:square;font-weight:bold;">
									<a href="/analytics" target="_blank">Analytics</a>
								</li>
								<li>
									<a href="https://partnernet.amazon.de/" target="_blank">Amazon PartnerNet</a>
								</li>
								<li>
									<a href="https://publisher.ebaypartnernetwork.com" target="_blank">eBay Partner Network</a>
								</li>
								<li>
									<a href="http://www.google.com/intl/de/analytics/" target="_blank">Google Analytics</a>
								</li>
								<li>
									<a href="https://www.google.com/adsense/?hl=de" target="_blank">Google AdSense</a>
								</li>
								<li>
									<a href="http://code.google.com/p/kammerath-network" target="_blank">Google Project</a>
								</li>
								<li>
									<a href="https://www.google.com/webmasters/tools/top-search-queries?hl=de&siteUrl=http://www.kammerath.net/" target="_blank">Google Webmaster Tools</a>
								</li>
								<li>
									<a href="http://www.facebook.com/insights/?sk=wo_10150096104452825" target="_blank">Facebook Insights</a>
								</li>
								<li>
									<a href="http://siteexplorer.search.yahoo.com/search?p=www.kammerath.net" target="_blank">Yahoo! Site Explorer</a>
								</li>
								<li>
									<a href="https://ui.zanox-affiliate.de/bin/z_in_frm.dll" target="_blank">Zanox Affiliate</a>
								</li>
							</ul>	
						</div>
					</div>
				{/if}
				
				<!-- ADBOX -->
				<div class="knSidebarBox">
					<div class="knSidebarBoxTitle">{$TEXT_OFFERS}</div>
					<div class="knSidebarBoxBody">
						<!-- 160x600-Sidebar -->
						<div id="knMasterSpaceRight"></div>

					</div>
				</div> 
			</td>
		</tr>
	</table>
	{include file='themes/desktop/javascript.tpl'}
</body>
</html>
